.class Lcom/teewoo/app/bus/ui/SearchByLineResultActivity$MyAdapter;
.super Landroid/widget/BaseAdapter;
.source "SearchByLineResultActivity.java"


# annotations
.annotation system Ldalvik/annotation/EnclosingClass;
    value = Lcom/teewoo/app/bus/ui/SearchByLineResultActivity;
.end annotation

.annotation system Ldalvik/annotation/InnerClass;
    accessFlags = 0x0
    name = "MyAdapter"
.end annotation


# instance fields
.field inflater:Landroid/view/LayoutInflater;

.field final synthetic this$0:Lcom/teewoo/app/bus/ui/SearchByLineResultActivity;


# direct methods
.method public constructor <init>(Lcom/teewoo/app/bus/ui/SearchByLineResultActivity;Landroid/content/Context;)V
    .locals 1
    .parameter
    .parameter "context"

    .prologue
    .line 199
    iput-object p1, p0, Lcom/teewoo/app/bus/ui/SearchByLineResultActivity$MyAdapter;->this$0:Lcom/teewoo/app/bus/ui/SearchByLineResultActivity;

    .line 197
    invoke-direct {p0}, Landroid/widget/BaseAdapter;-><init>()V

    .line 198
    invoke-static {p2}, Landroid/view/LayoutInflater;->from(Landroid/content/Context;)Landroid/view/LayoutInflater;

    move-result-object v0

    iput-object v0, p0, Lcom/teewoo/app/bus/ui/SearchByLineResultActivity$MyAdapter;->inflater:Landroid/view/LayoutInflater;

    return-void
.end method


# virtual methods
.method public getCount()I
    .locals 1

    .prologue
    .line 202
    iget-object v0, p0, Lcom/teewoo/app/bus/ui/SearchByLineResultActivity$MyAdapter;->this$0:Lcom/teewoo/app/bus/ui/SearchByLineResultActivity;

    invoke-static {v0}, Lcom/teewoo/app/bus/ui/SearchByLineResultActivity;->access$0(Lcom/teewoo/app/bus/ui/SearchByLineResultActivity;)Ljava/util/List;

    move-result-object v0

    invoke-interface {v0}, Ljava/util/List;->size()I

    move-result v0

    return v0
.end method

.method public getItem(I)Ljava/lang/Object;
    .locals 1
    .parameter "position"

    .prologue
    .line 206
    iget-object v0, p0, Lcom/teewoo/app/bus/ui/SearchByLineResultActivity$MyAdapter;->this$0:Lcom/teewoo/app/bus/ui/SearchByLineResultActivity;

    invoke-static {v0}, Lcom/teewoo/app/bus/ui/SearchByLineResultActivity;->access$0(Lcom/teewoo/app/bus/ui/SearchByLineResultActivity;)Ljava/util/List;

    move-result-object v0

    invoke-interface {v0, p1}, Ljava/util/List;->get(I)Ljava/lang/Object;

    move-result-object v0

    return-object v0
.end method

.method public getItemId(I)J
    .locals 2
    .parameter "position"

    .prologue
    .line 210
    int-to-long v0, p1

    return-wide v0
.end method

.method public getView(ILandroid/view/View;Landroid/view/ViewGroup;)Landroid/view/View;
    .locals 5
    .parameter "position"
    .parameter "convertView"
    .parameter "parent"

    .prologue
    .line 214
    iget-object v2, p0, Lcom/teewoo/app/bus/ui/SearchByLineResultActivity$MyAdapter;->inflater:Landroid/view/LayoutInflater;

    const v3, 0x7f03001f

    const/4 v4, 0x0

    invoke-virtual {v2, v3, v4}, Landroid/view/LayoutInflater;->inflate(ILandroid/view/ViewGroup;)Landroid/view/View;

    move-result-object v1

    .line 215
    .local v1, view:Landroid/view/View;
    iget-object v2, p0, Lcom/teewoo/app/bus/ui/SearchByLineResultActivity$MyAdapter;->this$0:Lcom/teewoo/app/bus/ui/SearchByLineResultActivity;

    invoke-static {v2}, Lcom/teewoo/app/bus/ui/SearchByLineResultActivity;->access$1(Lcom/teewoo/app/bus/ui/SearchByLineResultActivity;)[I

    move-result-object v2

    rem-int/lit8 v3, p1, 0x2

    aget v2, v2, v3

    invoke-virtual {v1, v2}, Landroid/view/View;->setBackgroundColor(I)V

    .line 216
    const v2, 0x7f0a004c

    invoke-virtual {v1, v2}, Landroid/view/View;->findViewById(I)Landroid/view/View;

    move-result-object v0

    check-cast v0, Landroid/widget/TextView;

    .line 217
    .local v0, txView:Landroid/widget/TextView;
    iget-object v2, p0, Lcom/teewoo/app/bus/ui/SearchByLineResultActivity$MyAdapter;->this$0:Lcom/teewoo/app/bus/ui/SearchByLineResultActivity;

    invoke-static {v2}, Lcom/teewoo/app/bus/ui/SearchByLineResultActivity;->access$0(Lcom/teewoo/app/bus/ui/SearchByLineResultActivity;)Ljava/util/List;

    move-result-object v2

    invoke-interface {v2, p1}, Ljava/util/List;->get(I)Ljava/lang/Object;

    move-result-object v2

    check-cast v2, Lcom/teewoo/app/bus/model/Line;

    invoke-virtual {v2}, Lcom/teewoo/app/bus/model/Line;->getName()Ljava/lang/String;

    move-result-object v2

    iget-object v3, p0, Lcom/teewoo/app/bus/ui/SearchByLineResultActivity$MyAdapter;->this$0:Lcom/teewoo/app/bus/ui/SearchByLineResultActivity;

    invoke-static {v3}, Lcom/teewoo/app/bus/ui/SearchByLineResultActivity;->access$2(Lcom/teewoo/app/bus/ui/SearchByLineResultActivity;)Ljava/lang/String;

    move-result-object v3

    const/high16 v4, -0x1

    invoke-static {v2, v3, v4}, Lcom/teewoo/app/bus/util/Utils;->highlightKeyword(Ljava/lang/String;Ljava/lang/String;I)Landroid/text/SpannableStringBuilder;

    move-result-object v2

    invoke-virtual {v0, v2}, Landroid/widget/TextView;->setText(Ljava/lang/CharSequence;)V

    .line 218
    return-object v1
.end method
